<B:UIWFN x:Class="WPFExcelReport.TWFAPP"
                    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
                    xmlns:ucd="clr-namespace:ReflectionStudio.Controls;assembly=ReflectionStudio.Controls"     
                    xmlns:me="clr-namespace:WPFExcelReport" 
                    xmlns:B="clr-namespace:WPFExcelReport;assembly=TICC_WFEVENTS" 
                    xmlns:ex="clr-namespace:WPFExcelReport.Controls;assembly=ExControls"   
                    xmlns:SD="clr-namespace:WPFExcelReport;assembly=TSDDAT"    
                    xmlns:WD="clr-namespace:WPFExcelReport;assembly=TICC_WFEVENTDEF"  
                    xmlns:BOOK="clr-namespace:WPFExcelReport;assembly=TICC_WFSUBSCRIBER"  
                    xmlns:Localization="clr-namespace:Localization;assembly=Localization" 
                    x:Name="TV"
                    Loaded="Window_Loaded"
     >
    <B:UIWFN.Resources>
        <CollectionViewSource  x:Key="vwMaster"/>       <CollectionViewSource  x:Key="vwDetail"/>
        <ucd:Divideby10  x:Key="d10"/>
        <ucd:BoolToVisibilityConverter  x:Key="bv"/>
        <ucd:Divideby100  x:Key="d100"/>
        <ucd:Divideby1000  x:Key="d1000"/>
        <ucd:GB2312Convert8859P1  x:Key="gb2312"/>
        <ucd:NOTConverter x:Key="not"/>
    </B:UIWFN.Resources>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition   Height="Auto" />
            <RowDefinition   Height="1*" />
            <RowDefinition   Height="Auto" />
        </Grid.RowDefinitions>
        <StackPanel Grid.Row="0"   Margin="0,0,-0.2,0">
            <WrapPanel >
                <ex:TXT72 Text="{Binding KRS,ElementName=TV}" Width="60"/>
                <ex:TXT72 Text="{Binding LFD,ElementName=TV}" Width="120"/>
                <ex:TXT72 Text="{Binding POS,ElementName=TV}" Width="60"/>
                <Button Margin="15,0,0,0" Content="{Binding Source={Localization:Translate Word=刷新}}" Click="QueryCommand"></Button>
            </WrapPanel>
            <WrapPanel IsEnabled="{Binding IsERL,ElementName=TV,Converter={StaticResource not}}">
                <TextBlock Text="{Binding Source={Localization:Translate Word=评审意见:}}"/>
                <ex:TXT72 Text="{Binding P1,Converter={StaticResource gb2312}}" Width="200"/>

                <Button   Click="ApproveCommand" Height="20" Margin="5,0,0,0" Width="24"  >
                    <Button.Background>
                        <ImageBrush  ImageSource="/ImagePackage;component/Images/button_ok.png" />
                    </Button.Background>
                </Button>
                <Button   Click="RejectCommand" Height="20" Margin="5,0,0,0" Width="24"  >
                    <Button.Background>
                        <ImageBrush  ImageSource="/ImagePackage;component/Images/redo.png" />
                    </Button.Background>
                </Button>
            </WrapPanel>
        </StackPanel>
        <DataGrid   Grid.Row="1" Grid.Column="0"  
                              AutoGenerateColumns="False"
                              EnableRowVirtualization="True"  
                              ItemsSource="{Binding Source={StaticResource ResourceKey=vwMaster}}"  
                              HeadersVisibility="Column"                           
                              ScrollViewer.HorizontalScrollBarVisibility="Auto"                
                              ScrollViewer.VerticalScrollBarVisibility="Auto" 
                Margin="0,0,0,0" 
                              >
            <DataGrid.Columns>
                <DataGridTextColumn Binding="{Binding Path=ROWNID}" Header="{Binding Source={Localization:Translate Word=ID}}"   Width="Auto"  MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=CONTROL}" Header="{Binding Source={Localization:Translate Word=状态}}"     Width="Auto"  MinWidth="30"/>
                <DataGridTextColumn Binding="{Binding Path=WFEUSER,Converter={StaticResource ResourceKey=gb2312}}"   Header="{Binding Source={Localization:Translate Word=订阅者}}"  Width="Auto" MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=P1, Converter={StaticResource ResourceKey=gb2312}}"   Header="{Binding Source={Localization:Translate Word=审核意见}}"  Width="120" MinWidth="80"/>
                <DataGridTextColumn Binding="{Binding Path=NEWUSER}" Header="{Binding Source={Localization:Translate Word=创建者}}"  Width="Auto" MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=NEWTIME}" Header="{Binding Source={Localization:Translate Word=创建日期}}"  Width="Auto" MinWidth="40"/> 
                <DataGridTextColumn Binding="{Binding Path=WFEVENTS}" Header="{Binding Source={Localization:Translate Word=事件}}"    Width="Auto"  MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=WFWHEN}" Header="{Binding Source={Localization:Translate Word=审核日期}}"  Width="Auto" MinWidth="40"/>               
                <DataGridTextColumn Binding="{Binding Path=WHAT, Converter={StaticResource ResourceKey=gb2312}}" Visibility="Collapsed" Header="{Binding Source={Localization:Translate Word=操作}}"  Width="120" MinWidth="60"/>
                <DataGridTextColumn Binding="{Binding Path=HOW, Converter={StaticResource ResourceKey=gb2312}}" Visibility="Collapsed" Header="{Binding Source={Localization:Translate Word=请求}}"  Width="120" MinWidth="80"/>
                <DataGridTextColumn Binding="{Binding Path=KRS}"   Width="Auto"  Visibility="Collapsed"  MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=LFD}" Header="{Binding Source={Localization:Translate Word=订单}}"  Visibility="Collapsed" Width="Auto"  MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=ARTICLE}" Header="{Binding Source={Localization:Translate Word=品种}}"   Visibility="Collapsed"  Width="Auto"  MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=COLOR}" Header="{Binding Source={Localization:Translate Word=色号}}"   Visibility="Collapsed"  Width="Auto"  MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=WFSOURCE}" Header="{Binding Source={Localization:Translate Word=来源}}"  Visibility="Collapsed"  Width="Auto" MinWidth="40"/>
                <DataGridTextColumn Binding="{Binding Path=WFEHANDLER}" Header="{Binding Source={Localization:Translate Word=处理}}"  Visibility="Collapsed"  Width="Auto" MinWidth="40"/>
            </DataGrid.Columns>
        </DataGrid>


    </Grid>
</B:UIWFN>
